<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        var allHour = prompt('抗洪战士连续作战（）小时')
        var day = parseInt(allHour / 24)
        var hour = allHour % 24
        alert('抗洪战士连续抗战' + day + '天' + hour + '小时')
    </script>
</body>

</html>